Repository navigation
Add text inventories of the HMI files, and a US/EU consistency check - #428
Open
jamesmulcahy wants to merge 4 commits into
Open
jamesmulcahy wants to merge 4 commits into
jamesmulcahy wants to merge 4 commits into
Conversation
The .HMI files are binary, so a PR that changes one shows nothing in review.
hmi_inventory.py (nextion-tools, run with uv) prints an HMI's pages, components,
selected attributes and event code as text. Each HMI's inventory is committed
next to it as <name>.HMI.txt, and CI fails when one no longer matches its HMI,
so an HMI change carries a readable diff.
.gitattributes marks *.HMI diff=hmi, so after
git config diff.hmi.textconv "uv run --quiet docker/HMI_files/hmi_inventory.py"
git diff and git log -p show the same view locally.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Generated with: uv run docker/HMI_files/hmi_inventory.py --write Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
hmi_compare.py compares the two projects by page and component name. It allows by rule what follows from the different screens: position and size, which picture is used (not whether there is one), font indices (fonts are compared by name and height), ids of components that don't report touches, and comments in code. Every other difference must be listed in hmi_us_eu_differences.txt, as `expected` (with a reason) or `todo`. CI fails on a difference that isn't listed, and on a listed one that has gone, so fixing a todo means deleting its line and the list only shrinks. It starts with 57 expected and 38 todo, among them the US dropdown's missing swipe to the thermostat page and the US thermostat's prev/next not ending a pending setpoint change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jamesmulcahy
marked this pull request as ready for review
November 8, 2026 03:20
Updated expected values for various UI elements to reflect differences between US and EU layouts. Removed several todo items that are now expected.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
.HMIfiles are binary, so a PR that changes one shows nothing in review. #427 (screensaver2replaced bycoverin #419) is the kind of change that goes unnoticed as a result. This PR adds a text inventory of each HMI that is checked in CI, plus a check that the US and EU HMIs stay consistent.What's here
1.
docker/HMI_files/hmi_inventory.py: prints an HMI's pages, components, selected attributes and event code as text. It uses nextion-tools, pinned to a commit and run withuv run(PEP 723 inline dependencies, so nothing to install beyond uv).gui.HMI.txt, about 5,200 lines each.font = 0 (hamlin18_latA 18),picc = 67 (320x480).uv run docker/HMI_files/hmi_inventory.py --write.2. Local
git diffof HMIs..gitattributesmarks*.HMI diff=hmi. Aftergit diffandgit log -pshow HMI changes as inventory diffs. GitHub ignores textconv, which is why the inventories are committed.3.
docker/HMI_files/hmi_compare.py: checks that the US and EU HMIs differ only where we know they do. It compares the two by page and component name and ignores, by rule:Every other difference must be listed in
hmi_us_eu_differences.txt, either asexpected(with a reason) ortodo. CI fails on an unlisted difference and on a listed one that no longer exists. Fixing atodotherefore means deleting its line, and the list can only shrink.Needs review: the differences list
The list starts with 57
expectedand 38todo. The classification is my first pass and needs someone who knows the HMIs to correct it.expected:lcd_dev;todocovers differences that look like one file got a change the other didn't, for example:dropdownhas no swipe to the thermostat page (tc0.val==18);thermostatprev/next don't end a pending setpoint change (deactivatetemp);slider_saveon load;dropdown's item buttons are global on US and local on EU;txt_maxlmismatches.todoalso covers a few that may well be deliberate. These only need a reason to becomeexpected.Testing
--checkandhmi_compare.pyboth pass ondevel's HMIs.hmi_compare.pyfails with a usable message when a difference isn't listed, when a listed difference no longer exists, and when anexpectedentry has no reason.🤖 Generated with Claude Code